﻿@page "/list-group"
@inject IStringLocalizer<ListGroups> Localizer

<h3>@Localizer["ListGroupsTitle"]</h3>

<h4>@Localizer["ListGroupsSubTitle"]</h4>

<Tips class="mt-3">
    <ul class="mb-0">
        @((MarkupString)Localizer["ListGroupsTips"].Value)
    </ul>
</Tips>

<DemoBlock Title="@Localizer["BasicUsageTitle"]"
           Introduction="@Localizer["BasicUsageIntro"]"
           Name="Normal">
    <div class="list-group-demo">
        <ListGroup TItem="Foo" Items="Items" Value="Value" GetItemDisplayText="@GetItemDisplayText"></ListGroup>
    </div>
</DemoBlock>

<DemoBlock Title="@Localizer["HeaderTextTitle"]"
           Introduction="@Localizer["HeaderTextIntro"]"
           Name="HeaderText">
    <div class="list-group-demo">
        <ListGroup TItem="Foo" Items="Items" Value="Value" GetItemDisplayText="@GetItemDisplayText" HeaderText="@Localizer["HeaderText"]">
        </ListGroup>
    </div>
</DemoBlock>

<DemoBlock Title="@Localizer["HeaderTemplateTitle"]"
           Introduction="@Localizer["HeaderTemplateIntro"]"
           Name="HeaderTemplate">
    <div class="list-group-demo">
        <ListGroup Items="Items" @bind-Value="Value" GetItemDisplayText="@GetItemDisplayText">
            <HeaderTemplate>
                <div class="list-group-header">
                    <div class="flex-fill">列表框</div>
                    <button class="btn btn-primary btn-xs">按钮</button>
                </div>
            </HeaderTemplate>
        </ListGroup>
    </div>
</DemoBlock>

<AttributeTable Items="GetAttributes()"></AttributeTable>
